package fr.esigelec.ping25;

import android.app.Activity;
import android.media.MediaRecorder;
import android.widget.Toast;

public class Traitement extends Activity implements Runnable
{
	public static boolean actif = true;
	
	private MediaRecorder media = null;
	
	
	public Traitement(MediaRecorder media)
	{
		this.media = media;
	}
	
	
	
	public void run()
	{	
		media.start();
		
		while(actif)
		{
			int vol = media.getMaxAmplitude();
		
			//BatterieActivity.texte.setText("Vol : " + vol);
		}
		
		(Toast.makeText(getApplicationContext(), "Fin...", 1)).show();
	}
}